home *** CD-ROM | disk | FTP | other *** search
/ ETO Development Tools 4 / ETO Development Tools 4.iso / Essentials / MacApp Documentation / MacApp.TECH$ Archives / 1989 / Dec 89 / 0136-DoInitViews()-Nov89 < prev    next >
Encoding:
Text File  |  1991-03-06  |  1.8 KB  |  51 lines  |  [TEXT/GEOL]

  1. Item forwarded  by  A33          to A34
  2.  
  3. Item    4545758                         29-Nov-89        10:44
  4.  
  5. From:   POWERUP.ENG                     Power Up Software,PRT
  6.  
  7. To:     MACAPP.TEST                     MacApp SQA Team
  8.  
  9. cc:     MACAPP.TECH$                    MacApp Technical
  10.  
  11. Sub:    DoInitViews()
  12.  
  13. Gentlepersons,
  14.  
  15. I am implementing a rather complex dialog that contains, among other things, a
  16. 'clear' button.  The 'clear' button restores the dialog to its initial state —
  17. the state specified by the view resources that define the dialog.  This
  18. specification includes such information as which controls are enabled, which
  19. are dimmed, what initial value each has, and so on.   I could write a routine
  20. that set all the controls to hard-coded values, but this is clearly redundant,
  21. and defeats the advantage of using view resources.
  22.  
  23. What I need, then, are some Init procedures that complement the DoCreateViews()
  24. and CreateAView() functions in TEventHandler.  Let's call the new procedures
  25. DoInitViews() and InitAView().  All of the code they need can be taken right
  26. out of DoCreateViews() and CreateAView(), which can be modified to call the new
  27. init routines, so there's little code actually added to the system.
  28.  
  29. As a complement to the global function NewTemplateWindow(), the procedure
  30. InitTemplateWindow() would take most of its code from NewTemplateWindow(), and
  31. could (once again) be called by the existing routine.
  32.  
  33. Wouldn't this be nice?
  34.  
  35. Looking forward to seeing these routines in a future version of MacApp, I
  36. remain
  37.  
  38. Yours,
  39.  
  40. James Plamondon
  41. Software Engineer
  42. PowerUp! Software
  43. 2929 Campus Drive, Suite 300
  44. San Mateo, CA  94403
  45. (415) 345-5900 x351
  46. AppleLink: PowerUp.Eng
  47.  
  48. P.S.:  In TEvetHandler.CreateAView(), the local variable anEntry:TEntry is
  49. unused, and should be removed from its VAR list.
  50.  
  51.